package com.test.controller;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * Created by apple on 2017/5/11.
 */

@Controller
@RequestMapping("/test2")
public class PageController {
    @Autowired
    private TestProperties mySize;

    @RequestMapping(value = "/home", method = RequestMethod.GET)
    String home() {
        return "Hello World! " + mySize.getContent();
    }

    @RequestMapping(value = {"/", ""}, method = RequestMethod.GET)
    String index() {
        return "index";
    }
}
